SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
CREATE VIEW dbo.vwbSolicitudes
AS
SELECT dbo.tb_Solicitudes.Alumno, dbo.tb_Solicitudes.Fecha, dbo.vwrTiposDeSolicitudes.Descripcion AS TipoSolicitud, dbo.vwrLineasDeBYP.Descripcion, 
               dbo.tb_Solicitudes.Urgencia
FROM  dbo.tb_Solicitudes INNER JOIN
               dbo.vwrTiposDeSolicitudes ON dbo.tb_Solicitudes.TipoSolicitud = dbo.vwrTiposDeSolicitudes.Id LEFT OUTER JOIN
               dbo.vwrLineasDeBYP ON dbo.tb_Solicitudes.idLineaDeByP = dbo.vwrLineasDeBYP.Id
GO
GRANT SELECT ON  [dbo].[vwbSolicitudes] TO [Becas]
GRANT SELECT ON  [dbo].[vwbSolicitudes] TO [SoloVer]
GO
